<?php
foreach($items as $item){
$image = $item->paths['small'];
$url = $item->paths['medium'];
?>
	<div class="pgallery_entry pg_image">
		<a href="<?php echo $url ?>" rel="group" class="fb_image" title="<?php echo $item->description ?>">
			<img src="<?php echo $image ?>" width="<?php echo $size ?>" height="<?php echo $size ?>" alt="<?php echo $item->name ?>" /></a>
			<span><?php echo $item->name ?></span>
		</a>
	</div>
<?php } ?>

<script type="text/javascript">
$(document).ready(function() {
	$("a.fb_image").fancybox({'overlayShow':false});
});
</script>